﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Microsoft.WindowsAzure;
using Microsoft.WindowsAzure.StorageClient;

namespace FeedReader.Shared.Data
{
    public class PostsDataServiceContext : TableServiceContext
    {
        public PostsDataServiceContext(string baseAddress, StorageCredentials credentials)
            : base(baseAddress, credentials)
        {
            //this.MergeOption = System.Data.Services.Client.MergeOption.NoTracking;
        }

        public const string PostsTableName = "PostsTable";

        public IQueryable<PostsDataModel> PostsTable
        {
            get
            {
                return this.CreateQuery<PostsDataModel>(PostsTableName);
            }
        }
    }
}
